{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 前言\n",
    "\n",
    "在我们使用 Jupyter Notebook 的时候，我们时常遇到一些小的问题，在这里做个记录。"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Jupyter Notebook 显示行号\n",
    "\n",
    "Jupyter Notebook默认不显示行号，不方便我们调试排错。操作如下：\n",
    "\n",
    "\n",
    "找到菜单`查看（View）`找到`切换（Toggle Line Numbers）`"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 报错:ImportError: cannot import name 'ensure_dir_exists'\n",
    "```\n",
    "conda update jupyter_core jupyter_client\n",
    "```"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# EnvironmentLocationNotFound: Not a conda environment\n",
    "\n",
    "参考链接：https://github.com/Anaconda-Platform/nb_conda/issues/66\n",
    "\n",
    "The reason is the change of conda info --json output. Fresh installation of version 4.3.33 gives envs=[], version >=4.4 gives envs=[root_env_dir] (always non empty).\n",
    "Fix:\n",
    "Replace for env in info['envs']] with for env in info['envs'] if env != info['root_prefix']] in nb_conda/envmanager.py.\n",
    "\n",
    "The method worked for me too, but the path should be anaconda_dir/lib/python3.6/site-packages/nb_conda/envmanager.py"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.5"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
